DecSoft BlockUI app plugin

This app plugin for DecSoft App Builder provide a couple of methods to block and unblock the user interface until some background task are made.

Methods

app.plugins.decsoft.blockui.block()

Use this method to block the user interface until some background task are made, for example. Calling to this method causes that the user cannot press or click in any app view control.

This method admits the below arguments:

Name Type Description
message String Specify the message to show to the user until the user interface is blocked. This message can be "Loading...", for example. The message can contain some HTML if you wanted. If you did not provide any message, a default spinner is shown, so in fact you can call to this method without pass any argument.
autoUnblockMs Number You can auto unblock the user interface by provided in this argument a milliseconds amount. After such milliseconds the user interface become unblocked automatically.
unblockedCallback Function Only if you provide a valid number for the "autoUnblockMs" argument, you can also specify here a callback JavaScript function, to be called when the user interface become unblocked.

app.plugins.decsoft.blockui.unblock()

Use this method to unblock the user interface, previously blocked by call to app.plugins.decsoft.blockui.block().

There is a BlockUI sample app included with the installation of DecSoft App Builder. Take a look to see this app plugin in action!